﻿using System;
using System.Runtime.Serialization;
using System.ServiceModel;

namespace XchangeStreamer.Server
{
    [MessageContract]
    [DataContract]
    public class XchangeMessage
    {
        [MessageHeader]
        [DataMember]
        public int TopicId
        {
            get;
            set;
        }

        [MessageHeader]
        [DataMember]
        public int MessageId
        {
            get;
            set;
        }

        [MessageHeader]
        [DataMember]
        public TimeSpan Time
        {
            get;
            set;
        }

        [MessageBodyMember]
        [DataMember]
        public byte[] Content
        {
            get;
            set;
        }
    }
}
